package com.launch.carmanager.data.dto;

import com.launch.carmanager.common.base.BaseRequest;
import com.launch.carmanager.common.base.BaseResponse;
import com.launch.carmanager.common.base.NullResponse;
import com.launch.carmanager.data.model.UserInfo;

import java.util.Map;

/**
 * Created by ganquan on 2019/3/28 15:19
 */
public class AuthDto {

    public static class AuthSendCodeRequest extends BaseRequest{
        private String mobileAccount;

        public AuthSendCodeRequest(String mobileAccount) {
            this.mobileAccount = mobileAccount;
        }

        @Override
        public Map<String, Object> getQueryMap() {
            return paramBuilder.add("mobileAccount", mobileAccount).get();

        }
    }

    public static class AuthRequest extends BaseRequest {

        private String mobileAccount;
        private String isCheckCode;
        private String registerStatus;

        public AuthRequest(String mobileAccount, String isCheckCode, String registerStatus) {
            this.mobileAccount = mobileAccount;
            this.isCheckCode = isCheckCode;
            this.registerStatus = registerStatus;
        }

        @Override
        public Map<String, Object> getQueryMap() {
            return paramBuilder.add("mobileAccount", mobileAccount).add("isCheckCode", isCheckCode).add("registerStatus",registerStatus).get();
        }
    }


    public static class AuthResponse extends BaseResponse<UserInfo>{

        public AuthResponse(String msg, int retcode, int errcode, UserInfo data) {
            super(msg, retcode, errcode, data);
        }
    }

    public static class AuthSendCodeResponse extends BaseResponse<NullResponse>{


        public AuthSendCodeResponse(String msg, int retcode, int errcode, NullResponse data) {
            super(msg, retcode, errcode, data);
        }
    }

}
